package com.example.novelstory.controller.dxy;


import com.example.novelstory.entity.Category2;
import com.example.novelstory.service.dxy.CategroyServicelmpl2;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import java.util.List;
import javax.annotation.Resource;
import org.springframework.web.bind.annotation.CrossOrigin;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RestController;


@Api(tags ="小说分类2")
@CrossOrigin
@RestController
public class CategoryController2 {
    @Resource
    CategroyServicelmpl2 categoryService2;

    @PostMapping(value = "/fingcategoryAll2")
//    @ResponseBody
    @ApiOperation(value = "全查")
    public List<Category2> findcategoryAll2() {
//        List<Category2> allcategoryUser2 = categoryService2.findcategoryAll2();
        return categoryService2.findcategoryAll2();
    }
//    @ResponseBody
    @PostMapping(value = "/findcategoryid")
    @ApiOperation(value = "查询")
    public List findcategoryid(Category2 category2) {
//        List<Category2> findcategoryid = categoryService2.findcategoryid(classification);
        return categoryService2.findcategoryid(category2);

    }

}
